<template>
  <div>
    <!-- 三级联动全局组件 -->
    <TypeNav></TypeNav>
    <!-- 列表 -->
    <ListContainer></ListContainer>
    <!-- 今日推荐 -->
    <Recommend></Recommend>
    <!-- 商品排行 -->
    <Rank></Rank>
    <!-- 猜你喜欢 -->
    <Like></Like>
    <!-- 楼层1 -->
    <Floor v-for="item in floorList" :key="item.id" :list="item"></Floor>
    <!-- 楼层2-->
    <!-- <Floor></Floor> -->
    <!-- 商标 -->
    <Brand></Brand>
  </div>
</template>

<script>
import { mapActions, mapState } from 'vuex'
import ListContainer from './ListContainer/ListContainer'
import Recommend from './Recommend/Recommend'
import Rank from './Rank/Rank'
import Like from './Like/index'
import Floor from './Floor/index'
import Brand from './Brand/Brand'
export default {
  name: '',
  components: {
    ListContainer,
    Recommend,
    Rank,
    Like,
    Floor,
    Brand
  },
  computed: {
    ...mapState({
      floorList: (state) => state.home.floorList
    })
  },
  created () {
    this.getFloorList()
    // this.getUserInfo()
  },
  methods: {
    ...mapActions('home', ['getFloorList']),
    // ...mapActions('user', ['getUserInfo'])
  }
}
</script>

<style></style>
